package com.spark.teaching.sparkfeign.service;

import com.spark.teaching.sparkfeign.hystric.ScheduleServiceHiHystric;
import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * 调用服务模板
 *
 * @author zhaoyiwu
 * @create 2017-09-30 11:08
 **/
@FeignClient(value = "service-hi",fallback = ScheduleServiceHiHystric.class)
//@FeignClient(value = "service-hi")
public interface ScheduleServiceHi {

    @RequestMapping(value = "/hi",method = RequestMethod.GET)
    String sayHiFromClientOne(@RequestParam(value = "name") String name);
}
